/* 全局样式 */
body {
    background-color: #f8f9fa;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

/* 导航栏样式 */
.navbar-brand {
    font-weight: bold;
    font-size: 1.5rem;
}

/* 卡片样式 */
.card {
    border: none;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
}

.movie-card {
    border-radius: 10px;
    overflow: hidden;
}

.movie-card .card-img-top {
    transition: transform 0.3s ease;
}

.movie-card:hover .card-img-top {
    transform: scale(1.05);
}

/* 按钮样式 */
.btn {
    border-radius: 5px;
    font-weight: 500;
    transition: all 0.2s ease;
}

.btn:hover {
    transform: translateY(-1px);
}

/* 表单样式 */
.form-control {
    border-radius: 5px;
    border: 1px solid #ced4da;
    transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

.form-control:focus {
    border-color: #80bdff;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

/* 轮播图样式 */
.carousel-item {
    border-radius: 10px;
    overflow: hidden;
}

.carousel-caption {
    background: rgba(0, 0, 0, 0.5);
    border-radius: 10px;
    padding: 20px;
}

/* 徽章样式 */
.badge {
    font-size: 0.75em;
    padding: 0.5em 0.75em;
}

/* 表格样式 */
.table {
    border-radius: 10px;
    overflow: hidden;
}

.table thead th {
    background-color: #f8f9fa;
    border-bottom: 2px solid #dee2e6;
    font-weight: 600;
}

/* 分页样式 */
.pagination .page-link {
    border-radius: 5px;
    margin: 0 2px;
}

.pagination .page-item.active .page-link {
    background-color: #007bff;
    border-color: #007bff;
}

/* 警告框样式 */
.alert {
    border-radius: 10px;
    border: none;
}

/* 页脚样式 */
footer {
    margin-top: auto;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .carousel-caption {
        padding: 10px;
    }
    
    .carousel-caption h2 {
        font-size: 1.5rem;
    }
    
    .carousel-caption p {
        font-size: 0.9rem;
    }
}

/* 自定义动画 */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.5s ease-in-out;
}

/* 座位选择样式 */
.seat-grid {
    display: grid;
    grid-template-columns: repeat(10, 1fr);
    gap: 8px;
    max-width: 600px;
    margin: 0 auto;
    padding: 20px;
}

.seat {
    width: 45px;
    height: 45px;
    border: 2px solid #dee2e6;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.75rem;
    font-weight: bold;
    background-color: #f8f9fa;
    position: relative;
    user-select: none;
}

.seat:hover:not(.sold):not(.disabled) {
    background-color: #e3f2fd;
    border-color: #2196f3;
    transform: scale(1.05);
    box-shadow: 0 2px 8px rgba(33, 150, 243, 0.3);
}

.seat.selected {
    background-color: #2196f3 !important;
    border-color: #1976d2 !important;
    color: white !important;
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(33, 150, 243, 0.4);
    animation: seatSelected 0.3s ease-in-out;
}

@keyframes seatSelected {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.15);
    }
    100% {
        transform: scale(1.1);
    }
}

.seat.sold {
    background-color: #f44336 !important;
    border-color: #d32f2f !important;
    color: white !important;
    cursor: not-allowed !important;
    opacity: 0.7;
}

.seat.disabled {
    background-color: #9e9e9e !important;
    border-color: #757575 !important;
    color: white !important;
    cursor: not-allowed !important;
    opacity: 0.5;
}

.seat:not(.sold):not(.disabled) {
    background-color: #f8f9fa;
    border-color: #dee2e6;
}

.seat:not(.sold):not(.disabled):active {
    transform: scale(0.95);
}

/* 座位选择信息样式 */
#selected-seats-display {
    background-color: #e3f2fd;
    border-color: #2196f3;
    color: #1976d2;
    font-weight: 500;
}

#selected-seats-list {
    font-weight: bold;
    color: #1565c0;
}

/* 价格显示样式 */
#total-price {
    font-size: 1.2rem;
    font-weight: bold;
    color: #d32f2f;
}

#price-per-seat {
    font-size: 1.1rem;
    font-weight: bold;
    color: #1976d2;
}

/* 按钮状态样式 */
#submit-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

#submit-btn:not(:disabled):hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 123, 255, 0.3);
}

/* 座位图例样式 */
.seat-legend {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
    padding: 1rem;
    background-color: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #dee2e6;
}

.seat-legend-item {
    display: flex;
    align-items: center;
    font-size: 0.9rem;
    font-weight: 500;
}

.seat-legend-item .seat {
    width: 30px;
    height: 30px;
    font-size: 0.7rem;
    margin-right: 0.5rem;
    cursor: default;
}

.seat-legend-item .seat:hover {
    transform: none;
    box-shadow: none;
}

/* 银幕样式 */
.screen {
    background: linear-gradient(135deg, #2c3e50, #34495e);
    color: white;
    padding: 0.75rem 2rem;
    border-radius: 8px;
    display: inline-block;
    margin-bottom: 2rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    font-weight: bold;
    text-align: center;
    min-width: 200px;
}

/* 响应式座位网格 */
@media (max-width: 768px) {
    .seat-grid {
        grid-template-columns: repeat(8, 1fr);
        gap: 6px;
        padding: 15px;
    }
    
    .seat {
        width: 40px;
        height: 40px;
        font-size: 0.7rem;
    }
    
    .seat-legend {
        flex-direction: column;
        gap: 0.5rem;
        align-items: center;
    }
}

@media (max-width: 576px) {
    .seat-grid {
        grid-template-columns: repeat(6, 1fr);
        gap: 4px;
        padding: 10px;
    }
    
    .seat {
        width: 35px;
        height: 35px;
        font-size: 0.65rem;
    }
}

/* 电影详情页样式 */
.movie-poster {
    border-radius: 10px;
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
}

.movie-info {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 10px;
    padding: 20px;
}

.rating-stars {
    color: #ffc107;
    font-size: 1.2rem;
}

/* 管理员面板样式 */
.admin-card {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 15px;
}

.admin-card .card-body {
    padding: 1.5rem;
}

/* 加载动画 */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* 自定义滚动条 */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: #555;
} 